<template>
  <div id="levrouter">
      <a href="javascript:;" @click="router('/ui_router','ui_router')">UI_Router</a> 
      <a href="javascript:;" @click="router('/contacts','contacts')">Contacts</a> 
      <a href="javascript:;" @click="router('/about','about')">About</a>
      <hr>
      <router-view></router-view>
  </div>
</template>

<script>
export default {
    name:'lev3router',
    methods:{
        router(targetPath,targetName){
            this.$router.push({
                path:targetPath,
                name:targetName
            })
        }
    }
}
</script>

<style lang="less" scoped>
       a{
        font-size: 16px;
        margin-right: 15px;
        text-decoration: underline;
        color: blueviolet;
    }
     a:hover{
         color: red;
    }
</style>